package com.heima.media.listener;

import com.heima.media.task.ArticleTask;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;

@Component
@Slf4j
public class ArticleDelayListener {
    @Autowired
    private ArticleTask articleTask;

    @PostConstruct
    public void handleMessage() throws Exception {
        log.info("=====================ArticleDelayListener执行=====================");
        articleTask.receiveMesasge();
    }
}
